Macro-expand interpreted code during load.
authorStefan Monnier <monnier@iro.umontreal.ca>
Tue, 4 Sep 2012 17:40:25 +0000 (13:40 -0400)
committerStefan Monnier <monnier@iro.umontreal.ca>
Tue, 4 Sep 2012 17:40:25 +0000 (13:40 -0400)
commit21c042bf50d9767149332ed3c610b1ffee743ec3
treede6672eda303c74456cfbfd812f754b0b1a1ed2d
parent2aab189d45ea5962eb7cbae09c4595c4aea305fd
Macro-expand interpreted code during load.
* src/lread.c (readevalloop): Call internal-macroexpand-for-load to perform
eager (load-time) macro-expansion.
* src/lisp.mk (lisp): Add macroexp.
* lisp/loadup.el: Load macroexp.  Remove hack.
* lisp/emacs-lisp/macroexp.el (macroexp--eval-if-compile): New function.
(macroexp--expand-all): Use it to get better warnings.
(macroexp--backtrace, macroexp--trim-backtrace-frame)
(internal-macroexpand-for-load): New functions.
(macroexp--pending-eager-loads): New var.
(emacs-startup-hook): New hack to replace one in loadup.el.
* lisp/emacs-lisp/cl-macs.el (cl--compiler-macro-list*)
(cl--compiler-macro-cXXr): Move to top, before they can be used.
(cl-psetf): Simplify.
(cl-defstruct): Add indent rule.
etc/NEWS
lisp/ChangeLog
lisp/emacs-lisp/cl-loaddefs.el
lisp/emacs-lisp/cl-macs.el
lisp/emacs-lisp/macroexp.el
lisp/emacs-lisp/pcase.el
lisp/loadup.el
src/ChangeLog
src/lisp.mk
src/lread.c